3.1.3 \(\int (c e+d e x) (a+b \text {ArcTan}(c+d x)) \, dx\) [3]

Optimal. Leaf size=48 \[ -\frac {1}{2} b e x+\frac {b e \text {ArcTan}(c+d x)}{2 d}+\frac {e (c+d x)^2 (a+b \text {ArcTan}(c+d x))}{2 d} \]

[Out]

-1/2*b*x*e+1/2*b*e*arctan(d*x+c)/d+1/2*e*(d*x+c)^2*(a+b*arctan(d*x+c))/d

________________________________________________________________________________________

Rubi [A]
time = 0.02, antiderivative size = 48, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.263, Rules used = {5151, 12, 4946, 327, 209} \begin {gather*} \frac {e (c+d x)^2 (a+b \text {ArcTan}(c+d x))}{2 d}+\frac {b e \text {ArcTan}(c+d x)}{2 d}-\frac {b e x}{2} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(c*e + d*e*x)*(a + b*ArcTan[c + d*x]),x]

[Out]

-1/2*(b*e*x) + (b*e*ArcTan[c + d*x])/(2*d) + (e*(c + d*x)^2*(a + b*ArcTan[c + d*x]))/(2*d)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 209

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*ArcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 327

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[c^(n - 1)*(c*x)^(m - n + 1)*((a + b*x^n
)^(p + 1)/(b*(m + n*p + 1))), x] - Dist[a*c^n*((m - n + 1)/(b*(m + n*p + 1))), Int[(c*x)^(m - n)*(a + b*x^n)^p
, x], x] /; FreeQ[{a, b, c, p}, x] && IGtQ[n, 0] && GtQ[m, n - 1] && NeQ[m + n*p + 1, 0] && IntBinomialQ[a, b,
 c, n, m, p, x]

Rule 4946

Int[((a_.) + ArcTan[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)*((a + b*ArcTan[c*x^
n])^p/(m + 1)), x] - Dist[b*c*n*(p/(m + 1)), Int[x^(m + n)*((a + b*ArcTan[c*x^n])^(p - 1)/(1 + c^2*x^(2*n))),
x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0] && (EqQ[p, 1] || (EqQ[n, 1] && IntegerQ[m])) && NeQ[m, -1]

Rule 5151

Int[((a_.) + ArcTan[(c_) + (d_.)*(x_)]*(b_.))^(p_.)*((e_.) + (f_.)*(x_))^(m_.), x_Symbol] :> Dist[1/d, Subst[I
nt[(f*(x/d))^m*(a + b*ArcTan[x])^p, x], x, c + d*x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && EqQ[d*e - c*f, 0
] && IGtQ[p, 0]

Rubi steps

\begin {align*} \int (c e+d e x) \left (a+b \tan ^{-1}(c+d x)\right ) \, dx &=\frac {\text {Subst}\left (\int e x \left (a+b \tan ^{-1}(x)\right ) \, dx,x,c+d x\right )}{d}\\ &=\frac {e \text {Subst}\left (\int x \left (a+b \tan ^{-1}(x)\right ) \, dx,x,c+d x\right )}{d}\\ &=\frac {e (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{2 d}-\frac {(b e) \text {Subst}\left (\int \frac {x^2}{1+x^2} \, dx,x,c+d x\right )}{2 d}\\ &=-\frac {1}{2} b e x+\frac {e (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{2 d}+\frac {(b e) \text {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,c+d x\right )}{2 d}\\ &=-\frac {1}{2} b e x+\frac {b e \tan ^{-1}(c+d x)}{2 d}+\frac {e (c+d x)^2 \left (a+b \tan ^{-1}(c+d x)\right )}{2 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 40, normalized size = 0.83 \begin {gather*} \frac {e \left (b (-d x+\text {ArcTan}(c+d x))+(c+d x)^2 (a+b \text {ArcTan}(c+d x))\right )}{2 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(c*e + d*e*x)*(a + b*ArcTan[c + d*x]),x]

[Out]

(e*(b*(-(d*x) + ArcTan[c + d*x]) + (c + d*x)^2*(a + b*ArcTan[c + d*x])))/(2*d)

________________________________________________________________________________________

Maple [A]
time = 0.07, size = 53, normalized size = 1.10

method result size
derivativedivides \(\frac {\frac {e \left (d x +c \right )^{2} a}{2}+\frac {b e \left (d x +c \right )^{2} \arctan \left (d x +c \right )}{2}-\frac {e \left (d x +c \right ) b}{2}+\frac {b e \arctan \left (d x +c \right )}{2}}{d}\) \(53\)
default \(\frac {\frac {e \left (d x +c \right )^{2} a}{2}+\frac {b e \left (d x +c \right )^{2} \arctan \left (d x +c \right )}{2}-\frac {e \left (d x +c \right ) b}{2}+\frac {b e \arctan \left (d x +c \right )}{2}}{d}\) \(53\)
risch \(-\frac {i e b \left (d \,x^{2}+2 c x \right ) \ln \left (1+i \left (d x +c \right )\right )}{4}+\frac {i e d b \,x^{2} \ln \left (1-i \left (d x +c \right )\right )}{4}+\frac {i e b c x \ln \left (1-i \left (d x +c \right )\right )}{2}+\frac {a d e \,x^{2}}{2}+\frac {e \arctan \left (d x +c \right ) b \,c^{2}}{2 d}+a c e x -\frac {b e x}{2}+\frac {b e \arctan \left (d x +c \right )}{2 d}\) \(113\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((d*e*x+c*e)*(a+b*arctan(d*x+c)),x,method=_RETURNVERBOSE)

[Out]

1/d*(1/2*e*(d*x+c)^2*a+1/2*b*e*(d*x+c)^2*arctan(d*x+c)-1/2*e*(d*x+c)*b+1/2*b*e*arctan(d*x+c))

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 124 vs. \(2 (45) = 90\).
time = 0.49, size = 124, normalized size = 2.58 \begin {gather*} \frac {1}{2} \, a d x^{2} e + \frac {1}{2} \, {\left (x^{2} \arctan \left (d x + c\right ) - d {\left (\frac {x}{d^{2}} + \frac {{\left (c^{2} - 1\right )} \arctan \left (\frac {d^{2} x + c d}{d}\right )}{d^{3}} - \frac {c \log \left (d^{2} x^{2} + 2 \, c d x + c^{2} + 1\right )}{d^{3}}\right )}\right )} b d e + a c x e + \frac {{\left (2 \, {\left (d x + c\right )} \arctan \left (d x + c\right ) - \log \left ({\left (d x + c\right )}^{2} + 1\right )\right )} b c e}{2 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d*e*x+c*e)*(a+b*arctan(d*x+c)),x, algorithm="maxima")

[Out]

1/2*a*d*x^2*e + 1/2*(x^2*arctan(d*x + c) - d*(x/d^2 + (c^2 - 1)*arctan((d^2*x + c*d)/d)/d^3 - c*log(d^2*x^2 +
2*c*d*x + c^2 + 1)/d^3))*b*d*e + a*c*x*e + 1/2*(2*(d*x + c)*arctan(d*x + c) - log((d*x + c)^2 + 1))*b*c*e/d

________________________________________________________________________________________

Fricas [A]
time = 2.61, size = 59, normalized size = 1.23 \begin {gather*} \frac {{\left (b d^{2} x^{2} + 2 \, b c d x + b c^{2} + b\right )} \arctan \left (d x + c\right ) e + {\left (a d^{2} x^{2} + {\left (2 \, a c - b\right )} d x\right )} e}{2 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d*e*x+c*e)*(a+b*arctan(d*x+c)),x, algorithm="fricas")

[Out]

1/2*((b*d^2*x^2 + 2*b*c*d*x + b*c^2 + b)*arctan(d*x + c)*e + (a*d^2*x^2 + (2*a*c - b)*d*x)*e)/d

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 95 vs. \(2 (41) = 82\).
time = 0.61, size = 95, normalized size = 1.98 \begin {gather*} \begin {cases} a c e x + \frac {a d e x^{2}}{2} + \frac {b c^{2} e \operatorname {atan}{\left (c + d x \right )}}{2 d} + b c e x \operatorname {atan}{\left (c + d x \right )} + \frac {b d e x^{2} \operatorname {atan}{\left (c + d x \right )}}{2} - \frac {b e x}{2} + \frac {b e \operatorname {atan}{\left (c + d x \right )}}{2 d} & \text {for}\: d \neq 0 \\c e x \left (a + b \operatorname {atan}{\left (c \right )}\right ) & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d*e*x+c*e)*(a+b*atan(d*x+c)),x)

[Out]

Piecewise((a*c*e*x + a*d*e*x**2/2 + b*c**2*e*atan(c + d*x)/(2*d) + b*c*e*x*atan(c + d*x) + b*d*e*x**2*atan(c +
 d*x)/2 - b*e*x/2 + b*e*atan(c + d*x)/(2*d), Ne(d, 0)), (c*e*x*(a + b*atan(c)), True))

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d*e*x+c*e)*(a+b*arctan(d*x+c)),x, algorithm="giac")

[Out]

sage0*x

________________________________________________________________________________________

Mupad [B]
time = 1.45, size = 73, normalized size = 1.52 \begin {gather*} a\,c\,e\,x-\frac {b\,e\,x}{2}+\frac {b\,e\,\mathrm {atan}\left (c+d\,x\right )}{2\,d}+\frac {a\,d\,e\,x^2}{2}+\frac {b\,c^2\,e\,\mathrm {atan}\left (c+d\,x\right )}{2\,d}+b\,c\,e\,x\,\mathrm {atan}\left (c+d\,x\right )+\frac {b\,d\,e\,x^2\,\mathrm {atan}\left (c+d\,x\right )}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c*e + d*e*x)*(a + b*atan(c + d*x)),x)

[Out]

a*c*e*x - (b*e*x)/2 + (b*e*atan(c + d*x))/(2*d) + (a*d*e*x^2)/2 + (b*c^2*e*atan(c + d*x))/(2*d) + b*c*e*x*atan
(c + d*x) + (b*d*e*x^2*atan(c + d*x))/2

________________________________________________________________________________________